<template>
  <el-dialog
    title="配置MCP接入点"
    :visible.sync="open"
    :before-close="cancel"
    width="600px"
    append-to-body
  >
    <el-form ref="form" :model="form" :rules="rules" class="dialog-form">
      <el-form-item label="选择MCP接入点" prop="key">
        <el-select v-model="form.value2" multiple collapse-tags placeholder="请选择">
          <el-option
            v-for="item in options"
            :key="item.value"
            :label="item.label"
            :value="item.value"
          >
          </el-option>
        </el-select>
      </el-form-item>
    </el-form>
    <div slot="footer" class="dialog-footer">
      <el-button type="primary" @click="submitForm">确 定</el-button>
      <el-button @click="cancel">取 消</el-button>
    </div>
  </el-dialog>
</template>

<script>
export default {
  props: {
    open: {
      type: Boolean,
      default: false,
    },
  },
  data() {
    return {
      form: {},
      rules: {},
      options: [
        {
          value: "选项1",
          label: "黄金糕",
        },
        {
          value: "选项2",
          label: "双皮奶",
        },
        {
          value: "选项3",
          label: "蚵仔煎",
        },
        {
          value: "选项4",
          label: "龙须面",
        },
        {
          value: "选项5",
          label: "北京烤鸭",
        },
      ],
    };
  },
  methods: {
    cancel() {
      const { item } = this;
      this.$emit("cancel", item);
    },
    submitForm() {
      
    },
    resetFormFun() {
      this.form = {};
      this.resetForm("form");
    },
    handleCopy() {},
  },
};
</script>

<style scoped lang="scss"></style>
